Expand description
pipecrab-audio: the platform-neutral boundary where audio enters and leaves a pipeline.
pipecrab-core owns the frame — AudioChunk and
AudioFormat, re-exported here for convenience. This crate owns how
audio crosses the pipeline edge: the AudioSource and AudioSink traits
plus hardware-free mock implementations for tests. Concrete backends
(e.g. cpal for desktop) live in their own crates behind these same traits.
Audio is a first-party pipeline payload — a typed
DataFrame::Audio, never a Custom
frame — so nothing here downcasts. Resampler defines audio-to-audio
conversion, ResamplerStage adapts it to the pipeline, and
RubatoSincResampler provides the bundled windowed-sinc default.
Modules§
- mock
- Hardware-free
AudioSource/AudioSinkimplementations for tests.
Structs§
- Audio
Chunk - A chunk of
f32PCM audio tagged with its ownAudioFormat. - Audio
Format - The wire format of an
AudioChunk: its sample rate and channel count. - Resampler
Effect - A conversion command emitted by
ResamplerStage. - Resampler
Stage - Adapts any
Resamplerinto a pipelineStage. - Rubato
Sinc Resampler - Streaming windowed-sinc sample-rate and channel-count conversion.
Enums§
- Audio
Error - Why an
AudioSource/AudioSink(or an underlying backend I/O) failed. - Resampler
Error - Why an audio chunk could not be converted by a
Resampler.
Traits§
- Audio
Sink - A sink of audio flowing out of a pipeline (device playback, file,
network, or a
mock). - Audio
Source - A source of audio flowing into a pipeline (device capture, file,
network, or a
mock). - Resampler
- A synchronous, stateful audio-to-audio format converter.